docs: improve the documentation of GtkEntry:attributes
authorSébastien Wilmet <swilmet@gnome.org>
Fri, 25 Nov 2016 19:08:00 +0000 (20:08 +0100)
committerSébastien Wilmet <swilmet@gnome.org>
Wed, 4 Jan 2017 18:56:30 +0000 (19:56 +0100)
See the implementation of gtk_entry_create_layout():
pango_attr_list_splice() is used to add the PangoAttrList of the preedit
string. And that is done *after* applying the PangoAttrList of the
"attributes" property.

https://bugzilla.gnome.org/show_bug.cgi?id=776868

gtk/gtkentry.c

index 4bc0be217d388436852da5ef57899b6238c88841..2a04129483c6819f24872f59454b2842946d9df1 100644 (file)
@@ -1378,6 +1378,9 @@ gtk_entry_class_init (GtkEntryClass *class)
    *
    * This is mainly useful to change the size or weight of the text.
    *
+   * The #PangoAttribute's @start_index and @end_index must refer to the
+   * #GtkEntryBuffer text, i.e. without the preedit string.
+   *
    * Since: 3.6
    */
   entry_props[PROP_ATTRIBUTES] =